import type { FormRules } from "element-plus";
// type FormType = "input" | "select" | "datePicker";
type DatePickerType =
  | "year"
  | "month"
  | "date"
  | "dates"
  | "datetime"
  | "week"
  | "datetimerange"
  | "daterange"
  | "monthrange";
interface IDatePickerType {
  type: DatePickerType;
  rangeSeparator: string;
  startPlaceholder: string;
  endPlaceholder: string;
}
export interface ISelectOptionType {
  value: string | number | boolean;
  label: string | number;
}
export interface IColLayoutType {
  span?: number;
  xl?: number;
  lg?: number;
  md?: number;
  sm?: number;
  xs?: number;
}
export interface IFormModuleType {
  param: string;
  label: string;
  placeholder?: string;
  type: "input" | "select" | "datePicker";
  datePickerProp?: IDatePickerType;
  selectOptions?: ISelectOptionType[];
  colLayout?: IColLayoutType;
  isHidden?: boolean;
}

export interface IFormConfigType {
  labelWidth?: string;
  labelPosition?: "left" | "right" | "top";
  size?: "large" | "default" | "small";
  rules?: FormRules;
}
